home *** CD-ROM | disk | FTP | other *** search
/ Amiga Collections: Scope / Scope Disk #060 (199x)(Scope PD)(US)[WB].zip / Scope Disk #060 (199x)(Scope PD)(US)[WB].adf / Noah / Part4 < prev    next >
Text File  |  1989-03-04  |  18KB  |  348 lines

  1.   And now, guess what?!  It's time for some more of that neat CLI stuff!!
  2. Oh please Mr. BenchMaster, can we have Assign first??
  3.  
  4.   Sorry kids, like desert, you'll have to finish your plates before we get
  5. to the good stuff, and that means every last byte!
  6.  
  7.   Okay, I'm just going to skip through the c directory; most of the commands
  8. just kind of do one thing so don't need much additional comment.
  9.  
  10.  
  11. AddBuffers-keep it until you get FaccII
  12. Assign-sorry, next chapter
  13. Break-Will stop some tasks that otherwise don't have an off command.
  14.       SetBeep is the only one that comes to mind.
  15. CD-sorry, next chapter too
  16. Copy-makes a copy of a file where you specify, with a different name if you
  17.      so further specify.  Use "all" to copy all directories and files.
  18. Date-shows or sets date
  19. Delete-deletes specified file unless "all" is used, then deletes specified
  20.        directory and all files/subdirectories within.
  21. Dir-shows specified directory's contents. Dir opt a for total Dir
  22. DiskDoctor-for recovering deleted files or files from a damaged disk
  23. Echo-for printing out text in a CLI window
  24. Ed-the script editor, also called a line editor
  25. Else, If, EndIf-next chapter
  26. EndCLI-closes CLI window; doesn't close if you've Run certain programs still
  27.        in operation, Runback might/will fix this.
  28. Execute-a "Run" for scriptfiles, if I may be so bold.
  29. FailAt-We're keeping it around as a sentimental reminder of how our our
  30.      startup-sequence USED to look.
  31. Fault-translates error message number into semi-English
  32. Info-already covered.  You can get a better one off the BBS's
  33. Install-to make a formatted disk bootable
  34. List-lists bytes in dir, to be replaced with DL, which will go into
  35.      directories in depth, giving you the full byteage.
  36. LoadWB-loads up the Workbench screen
  37. MakeDir-makes a new directory, but not the icon for it.  For the .info file
  38.         you have to copy over (and rename) another drawer icon, or make up
  39.         a new one in IconEd.
  40. NewCLI-it differs from the CLI command that was in the System drawer in only
  41.        one way, but you can play with them.  Both can have their window size
  42.        changed with NewZap.
  43. Path-ditto next chapter, and throughout.
  44. Prompt-changes the ">" sign for your CLI.  But why?
  45. Quit-will stop some programs from running
  46. Rename-renames files as well as moves them.  Learn this guy as well as Copy.
  47. Run-for tools/programs
  48. SetClock-for setting the internal and/or system clocks
  49. Stack-you won't need this until you get into animations but I left it in,
  50.       just in case some graphics hack you've downloaded wants it.  If so,
  51.       there'll be numbers in the STACK box in the Info window.
  52. Status-gives you general status of CLI tasks.  Like Info, there are better
  53.        ones around but I find this one adequate.
  54. Type-goes into the dumper as soon as you get Less.
  55. Version-left in just in case somebody/something wants it.
  56. Wait-holds up CLI process for requested number of secs/mins
  57. Why-like Fault, gives you feedback on error.  Use right after boo-boo.
  58.  
  59.   Okay, that's it for these clowns.
  60.  
  61.                                        *
  62.  
  63.   Well, I fibbed.  This is the next chapter and we're NOT going to go
  64. over those other commands just yet.  Aw-w, gee Uncle BenchMaster, c'mon,
  65. just one little Assign, pretty-please???
  66.  
  67.   Well, okay.  Geez, I'm such a sucker for you brats.  Now, remember when I
  68. said we'd wipe out the fonts dir, get all the space back and still have
  69. access to the fonts?  Here's how:  We'll make a fresh fonts dir on a blank
  70. disk and Assign fonts over to that disk, so when Notepad or whatever goes
  71. looking for fonts, there they'll be.  Put a freshly formatted disk in df1
  72. and rename it FontDisk.  Type "MakeDir df1:fonts", and you should have a
  73. fonts dir on FontDisk.  If you still have all the fonts in your Workbench
  74. directory, type "Copy fonts df1:fonts all".  If you've already blasted them,
  75. boot up your Workbench 1.2 and copy them over.  Now to run Notepad with
  76. df1's fonts, somewhere before you start up Notepad you need to Assign the
  77. fonts over to df1, which you can do a number of ways.
  78.  
  79.   -  You can just put "Assign fonts: df1:fonts" in your st-seq but then
  80. FontDisk always has to be in df1 when you're booting up or it's no-go.
  81.  
  82.   -  A variation on the above would be to put a
  83.  
  84.                If exists df1:fonts
  85.                Assign fonts: df1:fonts
  86.                endif
  87.  
  88. in the st-seq so it can see if df1:fonts is there or not.  One hitch
  89. with this is that unless FontDisk is in df1 during boot-up you'll STILL
  90. have to Assign them over before using the Notepad.  Also, you could have
  91. some ol' game disk with a font dir on it in df1 by mixtake and things would
  92. really get mixed up.
  93.  
  94.   -  You could, of course, just type "Assign fonts: df1:fonts" in a CLI
  95. before using the Notepad every time.  Personally, I can't even imagine it.
  96.  
  97.   -  You could write a script file saying nothing but "Assign fonts: df1:
  98. fonts", call it, say, "fo" (for fonts), and go "f fo" before firing up the
  99. Notepad.  But then, of course, you still have to remember to do it.
  100.  
  101.   -  You could use Xicon and run that same script file from an icon,
  102. located, say, right next to the Notepad icon and that would do it for you.
  103.  
  104.   -  Or, of course, you could do it the right way.  I've given you enough
  105. clues in these pages to let you piece it together for yourself.  Remember
  106. what I said about a program running from a script file:  Unless it's Run it
  107. stops the file from continuing.  That's the deal.
  108.  
  109.                                        *
  110.  
  111.   A few mentions on the new programs you've downloaded/are downloading..
  112.  
  113. The basic gang:
  114.  
  115. Conman - Only makes the CLI about 2000% times easier to use.  Use -q -t in
  116.          your st-seq.
  117.  
  118. Lace - It still has a few bugs.  The perfect Lace would remember where the
  119.        window were.
  120.  
  121. Less - Allows you to Ed with "v", use "g" and "G" for top & bottom of page.
  122.        This is the only program I can think of that uses "hot keys", meaning
  123.        you don't have to hit the Return.  Rename it as Type.
  124.  
  125. Less - Rename this as Type.
  126.  
  127. PrefCh - Can also be used for different printer set-ups, of course.
  128.  
  129. Mackie - Must be RunBack'd in st-seq.
  130.  
  131. Runback - Always use instead of Run in a scriptfile, like st-seq.
  132.  
  133. Select - If DU-VI doesn't get Best Program, I nominate this guy.  It can be
  134.          used in a lot of great ways.
  135.  
  136. Xicon201 - No real difference between this and older version (except size).
  137.  
  138.  
  139. Others:
  140.  
  141. DL - Rename it List2, use List for JUST a directory, List2 -R -s (dir) for
  142.      in-depth look.  Has to be capital "R".
  143.  
  144. Blitzfonts - not necessary, just one of those programs where once you get
  145.              used to it you notice it immediately when it's gone.  Use
  146.              Runback in st-seq.
  147.  
  148. Zoomlens - can actually be handy for inspecting icons to see how to get
  149.            green, purple and brown from the stock four colors.  Interesting!
  150.  
  151. SetBeep - This does have a few bugs.  Get a newer or different one when you
  152.           can.  Use Runback in st-seq.
  153.  
  154.                                        *
  155.  
  156.   Let's go over CD for a sec just to make sure you're familiar with it.  If
  157. there's any command on the disk that's "ours", CD is it.  Basically, it means
  158. you, meaning your fingers, meaning the keyboard, meaning where the
  159. commands being typed on the screen are coming from.  You can CD to any
  160. device and into any directory.  Type "CD Ram:" and you're in Ram.  How do
  161. you know?  Type "CD" and it'll tell ya.  If you type "Dir" then you'll be
  162. shown what's in "your" directory and/or device.  Type "CD df0:System",
  163. then type "Dir".  Dir will show you what's in the directory you've CD'd to.
  164. You don't have to CD to a directory to find out what's in it, of course.
  165. Type "CD df0:", then type "CD" and it should spit the Bench's name back at
  166. you.  Type "Dir" and there's the stuff on the "surface" of the disk. Then
  167. type "Dir System" and there's the System stuff.  You already know this?
  168. Great, no problem.
  169.  
  170.   CD can save us a bunch of keystrokes if we're writing a script file and
  171. have to copy or rename or whatever a bunch of files buried deep in some
  172. directory.  Let's say we've got a disk with nothing but IFF pictures on
  173. it, a whole bunch of them, all in separate directories.  We want to write a
  174. file that when we Execute it it will copy just certain pics to Ram.  So first
  175. we "Ed s/pics1", which will create a new script file called "pics1" located
  176. in the directory s.  The pics we want to copy to Ram are in a directory, on
  177. df1, called Modern, inside a directory called Art, inside a directory called
  178. Pics, inside a directory called Graphics.  Since this is already confusing
  179. enough, we'll just call the pics 1,2,3,4 and 5.  Using Ed, we'd write
  180.  
  181.                      copy df1:Graphics/Pics/Art/Modern/1 Ram:
  182.                      copy df1:Graphics/Pics/Art/Modern/2 Ram:
  183.                      copy df1:Graphics/Pics/Art/Modern/3 Ram:
  184.                      copy df1:Graphics/Pics/Art/Modern/4 Ram:
  185.                      copy df1:Graphics/Pics/Art/Modern/5 Ram:
  186.  
  187.              Whew!  With the CD command, we can do this:
  188.  
  189.                      cd df1:Graphics/Pics/Art/Modern
  190.                      copy 1 Ram:
  191.                      copy 2 Ram:
  192.                      copy 3 Ram:
  193.                      copy 4 Ram:
  194.                      copy 5 Ram:
  195.  
  196.   See that?  It put us into the Modern dir and then when we said to Copy
  197. (or Rename or whatever) a file, the computer knew just where to find it, as
  198. it was right there "alongside".
  199.  
  200.   As you've noticed, I've been playing pretty fast and loose with the words
  201. "directory" and "drawer", and not by accident.  You might as well get used
  202. to them meaning (approximately) the same thing, kind of like that program/
  203. tool/utility business.  I'm tending to just use them as the occasion fits;
  204. you put things into drawers but you dir a directory, assuming that makes
  205. sense.
  206.  
  207.   If you haven't downloaded Conman yet, you're really missing the boat.  I
  208. guarantee it'll be one of your best buddies forever.  I give it my highest
  209. praise:  It should have been included with the original software.  I'd even
  210. settle for that tool dir on the Extras/Basic disk.  Which, yes, we'll get to
  211. eventually.  Don't hold your breath, there's not much on it for the likes of
  212. us.
  213.  
  214.                                        *
  215.  
  216.   Figured out that deal with Notepad and the fonts yet?
  217.  
  218.                                        *
  219.  
  220.   There are two great keyboard commands that as far as I know aren't
  221. documented anywhere, probably a 1.2 upgrade.  I read about them in a
  222. letter to AmigaWorld..what can I say?  They're Commodore-N and Commodore-M.
  223. They flip you back and forth between screens, two much-used commands.  If a
  224. program, like gShow, mentions "toggle", that's what it means.
  225.  
  226.                                        *
  227.  
  228.   You're probably getting a handle on Path, that elusive rascal.  Path shows
  229. the computer where directories are so it can find tools when you command it 
  230. to.  One thing you have to remember about Path is that it only leads to the 
  231. one you name, even if it has to go through a couple of directories to do it.
  232. The directories it goes through to get to yours are not in the path until
  233. specifically named.  I'm not sure if this makes sense or not; I haven't been
  234. in a situation where I wanted to make sure something DIDN'T have a path for
  235. it or to it.  Now that I've said that I'm sure one will arise.  Just Path
  236. everything that has a tool in it during the st-seq and be done with it.
  237.  
  238.                                        *
  239.  
  240.   Okay...NOW we'll do Assign.  Nothing to it, really.  Simply Assign any
  241. directory to what and where you want and that's it.
  242.  
  243.                                        *
  244.  
  245.   Now I'd like to say a few words about the program Xicon.  It's one of the
  246. more integral programs on your download list, meaning that it touches a lot
  247. of areas of the computer.  I'm not going to call it a subroutine, though,
  248. as it only works when called upon, like any tool, whereas Mackie and 
  249. FaccII and the like are "always" running in the background, and that's
  250. easily proved by quitting the programs and watching the memory they were
  251. using come back.  Some subroutines, like Conman and Newfont, don't have off
  252. switches, so once they're run the memory's gone.  That, again, is where
  253. Select comes into play, which we'll get to by and by.  What's that?  You
  254. thought the section on Assign was kind of skimpy?  Are you sure??  Look,
  255. I'll make you a deal:  YOU solve the Notepad/fonts puzzle and I'll give you
  256. another whole paragraph on Assign..fair enough?  Now put this down and get
  257. busy, gol'dang it!
  258.  
  259.                                        *
  260.  
  261.   Generally, the proper proceedure for using Xicon is this:  (I elaborate on
  262. this program because the doc is kinda hefty)
  263.  
  264.   Let's say we want to run a program, any program, say, Notepad for
  265. instance.  The only hitch is that on the Bench we've only got some lonesome
  266. ol' Topaz 11 kickin' around the fonts drawer, all the good stuff's on
  267. FontDisk.  We haul out Ed and write up a script file for Xicon to run.  We
  268. type "Ed Utilities/Notepad!", note that the exclamation mark differs it from
  269. the program "Notepad".  You can use any name, "Note.Pad" for all I care,
  270. just so long as it's not the actual program's name.  So our script file
  271. looks like this:
  272.  
  273.                           Assign fonts: df1:fonts
  274.                           CD df0:Utilities
  275.                           Notepad
  276.                           Assign fonts: df0:fonts
  277.  
  278.  
  279.   First we assigned the fonts directory over to the one on df1, so when
  280. Notepad went looking for fonts, it was re-directed to the fonts dir on df1.
  281. Then we ran the Notepad program, but we didn't Run it, that's the deal.  If
  282. we'd Run it the script file would have continued, the fonts dir would have
  283. been reassigned to df0 and Notepad wouldn't have found them.  This way they
  284. stay on df1 until the Notepad program is ended, allowing the script file to
  285. continue.  This is an elemental part of the whole Amiga scheme so make sure
  286. you understand it.  Did I call it a "puzzle"?  Excuse me.
  287.  
  288.   So you've got your file written, Esc-X, Return to save it.  By the way, I
  289. CD'd into the Utilities directory before running the Notepad because Xicon
  290. likes you to CD into the directory.  It wasn't essential; you'll use Xicon a
  291. lot and discover its workings.  The next step is to change the Notepad
  292. icon from a tool to a project, as Xicon need a project icon to run from.  If
  293. you don't have IconType or IconLab yet (where have you BEEN?), haul out good
  294. ol' IconEd, load up a project icon and the Notepad icon and do the switch.
  295. Save it as "df0:Utilities/Notepad!" (the .info is added automatically) to
  296. match our (!) scriptfile.
  297.  
  298.   Close IconEd, open the Utilities drawer and there our icon should be.
  299. Double-click it just to watch the error message and make a fool of yourself,
  300. then activate the icon and pull down the Info menu.  Activate the Default
  301. Tool box with the mouse then type in "df0:c/Xicon", hit Return, then SAVE
  302. the Info.  Ready for the big moment?  Double-click the icon, things should
  303. scratch around for a while then up Notepad should pop.  Check the fonts to
  304. make sure they're loaded.  Quit the program, the fonts should re-assign
  305. themselves to df0, and that's that.  The box Xicon popped up is VERY valuable
  306. when getting a scriptfile running as that's your feedback window, which,
  307. hopefully, will tell you if something's screwing up.  Like if you didn't have
  308. FontDisk in df1 and the Assign failed, it'll tell you.  After the program's
  309. running smooth, re-open the Info window for the icon, click the ADD box and
  310. enter in the Tool Types box:  MODE=nowindow    That'll keep the window from
  311. opening.  It also one of the few times capitals count; any command in the
  312. Tool Types box is ALWAYS capitalized, far as I know.  If you have the older
  313. version of Xicon you'll type   MODE=closewindow.
  314.  
  315.   An improvement in the scriptfile would be to say
  316.  
  317.                            Assign fonts: FontDisk:fonts
  318.  
  319. to make sure the Assign seeks out the disk by name, in which case you'll get
  320. a requester if Fontdisk isn't in df1.
  321.  
  322.   Xicon, remember, is only for running scriptfiles from the Workbench.  You
  323. could always rename that Notepad! script to "n", put it in the s dir, and as
  324. fast as your fingers could type "f n", you'd be on your way.  Given how
  325. small, byte-wise, a script file is, you could have both.  Yes, but I hear
  326. you say, as long as you have to open Utilities to get to the CLI icon, why
  327. not just punch Notepad! as long as you're there?  Well, that, my friend,
  328. is because you don't have a handy little CLI window or two pop open down at
  329. the bottom of your Bench during boot-up for just such an occasion.  But you
  330. will, you will...
  331.  
  332.                                        *
  333.  
  334.   A few words on If, EndIf and Else.  Unless you want to get cute and start
  335. using all the sub-commands that go along with these three, things are pretty
  336. straightforward.  Take a glance in one of the DOS books if you forget the
  337. correct format.  Basically, it just checks to see if a file or directory (or
  338. device, I suppose) is there, and then does something or not.  The something
  339. it does can be a whole string of commands or nothing.  Ditto if the file
  340. isn't there.  The reason that mess is in the startup-sequence is just
  341. in case some fool renames either the System or Utilities directories, in
  342. which case the Path command would fail.  That's not so bad; the scriptfile
  343. (in this case the st-seq) would continue to execute.  In a case like Assign,
  344. however, it would grind to a halt..so the commands CAN be important.
  345.  
  346.                                        *
  347.  
  348.